
import request from '@/utils/request'
// 组织架构的请求

// 获取组织架构数据
export const getDepartments = () => request.get('/company/department')

//  根据id根据部门  接口是根据restful的规则设计的   删除 delete  新增 post  修改put 获取 get
// 封装删除功能模块
export const delDepartments = (id) => request.delete('/company/department/' + id)

// 新增部门接口
export const addDepartments = (data) => request.post('/company/department/', data)

// 封装获取简单员工列表的模块
export const getEmployeeSimple = () => request.get('/sys/user/simple')

// 根据ID查询部门详情
export const getDepartDetail = (id) => request.get('/company/department/' + id)

// 根据ID修改部门详情
export const updateDepartments = (data) => request.put(`/company/department/${data.id}`, data)

